#include <bits/stdc++.h>

using namespace std;

class Solution
{
public:
    int maxWidthOfVerticalArea(vector<vector<int>> &points)
    {
        set<int> tmp;
        for (int i = 0; i < points.size(); ++i)
        {
            tmp.insert(points[i][0]);
        }

        int ret = 0;
        auto before = tmp.begin();
        auto next = ++tmp.begin();
        while (next != tmp.end())
        {
            ret = max(ret, *next++ - *before++);
        }
        return ret;
    }
};